import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
import os
import scipy.io
import math
from spatial_preprocess import process_matlab,calGRF


index_files_path = "D:/A_SEU/SFBD/IndexFiles/"
data_files_path = "D:/A_SEU/SFBD/SFootBD/"



train_list_file = index_files_path + 'LstTrain'
train_list = pd.read_csv(train_list_file, sep = ' ', header = None)
mat_file = os.path.join(data_files_path, train_list[1][0] + '.mat')

mat = scipy.io.loadmat(mat_file)
processed = process_matlab(mat)
plt.imshow(processed, cmap='jet', origin='lower')


